<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%
 String path = request.getContextPath();
 String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>
<%@ page isELIgnored="false" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<html>
<head>
  <meta charset="utf-8">
  <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
  <title>ChrosWine管理系统</title>
  <link rel="stylesheet" href="<%=path%>/source/CSS/layui.css">
</head>
<body class="layui-layout-body">
	<% request.setCharacterEncoding("UTF-8"); %>
	<div class="layui-layout layui-layout-admin">
	  <div class="layui-header">
	    <div class="layui-logo">ChrosWine管理系统</div>
	    <!-- 头部区域（可配合layui已有的水平导航） -->
	    <ul class="layui-nav layui-layout-right">
		  <li class="layui-nav-item">
		    <img src="<%=path%>/source/image/Logo.jpeg" class="layui-nav-img"><font>${session_user.name}</font>
		    <dl class="layui-nav-child">
		      <dd><a href="/Management/servlet/PageDao?action=PSW&code=${session_user.stuCode}">修改密码</a></dd>
		      <dd><a href="<%=request.getContextPath() %>/servlet/LoginOut">退出系统</a></dd>
		    </dl>
		  </li>
	    </ul>
	  </div>
	  
	  <div class="layui-side layui-bg-black">
	    <div class="layui-side-scroll">
	      <!-- 左侧导航区域（可配合layui已有的垂直导航） -->
	      <ul class="layui-nav layui-nav-tree"  lay-filter="test">
	      		<li class="layui-nav-item">
		          <c:if test="${session_user.roleId==0}">
	      		  	<a href="/Management/servlet/PageDao?action=ManagerDefault" method="post">首页</a>
	      		  </c:if>
		        </li>
	      	<!-- 管理员 -->
	      	<c:if test="${session_user.roleId==0}">
	      		<li class="layui-nav-item">
	      		  	<a href="/Management/servlet/PageDao?action=CompanyIntro" method="post">公司简介</a>
		        </li>
	      		<li class="layui-nav-item">
	      		  	<a href="/Management/servlet/PageDao?action=StaffRe" method="post">招贤纳士</a>
		        </li>
			    <li class="layui-nav-item">
			        <a href="/Management/servlet/PageDao?action=WineCatogory">红酒分类</a>
			    </li>
			    <li class="layui-nav-item">
			        <a href="/Management/servlet/PageDao?action=ProductManage">产品管理</a>
			    </li>
			    <li class="layui-nav-item">
			        <a href="/Management/servlet/PageDao?action=WineKnologe">红酒知识</a>
			    </li>
	      		<li class="layui-nav-item">
	      		  	<a href="/Management/servlet/PageDao?action=CpNews" method="post">公司资讯</a>
		        </li>
			    <li class="layui-nav-item">
			        <a href="/Management/servlet/PageDao?action=Manager&code=${session_user.stuCode}">管理员</a>
			    </li>
	        </c:if>
		     <li class="layui-nav-item">
		          <a href="<%=request.getContextPath() %>/servlet/LoginOut">退出系统</a>
		     </li>
	      </ul>
	    </div>
	  </div>
	  
	  <div class="layui-body">
	    <!-- 内容主体区域 -->
	    <div>
        <c:if test="${session_user.roleId==0}">
        	<jsp:include page="${mainRight==null ? 'ManagerDefault.jsp': mainRight }"></jsp:include>
        </c:if>
        </div>
	  </div>
	  
	  <div class="layui-footer">
	    <!-- 底部固定区域 -->
	    @2020-2025底部固定区域
	  </div>
	</div>


	<script src="<%=path%>/source/JS/layui.js"></script>
	<script>
	//JavaScript代码区域
	layui.use('element', function(){
	  var element = layui.element;
	  
	});
	
	
	
	</script>
</body>
</html>